package com.usbserial.transaction;

import java.io.Closeable;
import java.util.List;

/**
 * Consumes raw byte buffers and emits framed payloads.
 */
public interface FrameDecoder<T> extends Closeable {
    List<T> decode(byte[] chunk);

    void reset();

    @Override
    default void close() {
        reset();
    }
}
